package com.wantup.miaosha.service.impl;

import com.wantup.miaosha.mapper.TblGoodsMapper;
import com.wantup.miaosha.pojo.GoodsPojo;
import com.wantup.miaosha.service.GoodsService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author Zhaoluowei
 * @version 1.0
 * @date 2019/6/6 13:42
 */
@Service
@Slf4j
public class GoodsServiceImpl implements GoodsService {

    @Autowired
    private TblGoodsMapper tblGoodsMapper;

    @Override
    public List<GoodsPojo> getGoodsListVo(){
        return this.tblGoodsMapper.listGoodsVo();
    }

    /**
     * 获取鱼护信息
     * @param id
     * @return
     * @throws Exception
     */
    @Override
    public GoodsPojo getGoodsInfoByGoodsId(String id) throws Exception {
        return this.tblGoodsMapper.getGoodsInfoByGoodsId(id);
    }


}
